import authentication from '../utils/authentication';
import request from '../utils/request';

const auth = {
    // 用户注册
    register(data) {
        return authentication.register(data);
    },
    // 用户登录
    login(data) {
        return authentication.login(data);
    },
    //发送验证码
    sendVerifyCode(email, type) {
        return request.post('/auth/sendVerifyCode', { email: email, type: type });
    },
    resetPassword(data) {
        return request.post('/auth/resetPassword', data);
    },
};

export default auth;
